Recently, a magnetic disk device includes a power loss protection (PLP) function of assuring write data that is not written to a disk (i.e., unwritten data) by saving (or caching) write data to an nonvolatile memory, etc., in a case where a failure unexpectedly occurs in a main power supply. The PLP function includes a function of saving unwritten data cached in a volatile memory, etc., and management information of the unwritten data, to the nonvolatile memory, etc., in the case where the failure occurs in the main power supply. Such an operation is often referred to as a PLP saving operation. When the main power supply is recovered, a magnetic disk device can restore the unwritten data saved to the nonvolatile memory, etc., by the PLP saving operation, to the volatile memory, based on the management information.
In addition, the magnetic disk device can queue a write command from a host system, in a general write operation, by saving the write data to the nonvolatile memory, etc., by the PLP function. In other words, the magnetic disk device can assure the unwritten data in a case where the failure occurs in the main power supply, even in a state of invalidating the write cache, and efficiently writing the write data to a disk, similarly to a case of validating the write cache, by the PLP function. The magnetic disk device can increase an amount (i.e., queuing amount) of the write commands which can be queued, in accordance with the data amount (i.e., PLP amount) which can be assured by the PLP function. The PLP amount depends on the capacity of the nonvolatile memory, etc. Furthermore, the PLP amount can be virtually increased by forming a media cache area in a disk and saving the write data to the media cache area.